package edu.ccut.saturn.basecomponent.database;

/**
 * 
 * @author Tony Yan
 * 
 */
public interface ISelectSQLBuilder {
	
	/**
	 * 查询Count值SQL构建接口
	 * 
	 * @param fullKey
	 * @param condition
	 * @return
	 */
	ISaturnSQL build2(String fullKey, String condition) throws Exception;
	
	/**
	 * 查询Count值SQL构建接口
	 * 
	 * @param fullKey
	 * @param condition
	 * @param tableWord 表名或分区语句关键字
	 * @return
	 */
	ISaturnSQL build2(String fullKey, String condition, String tableWord) throws Exception;
	
	/**
	 * 一般查询SQL构建接口
	 * 
	 * @param fullKey
	 * @param condition
	 * @return
	 */
	ISaturnSQL build(String fullKey, String condition) throws Exception;

	/**
	 * 分页查询SQL构建接口
	 * 
	 * @param fullKey
	 * @param condition
	 * @param startIndex
	 * @param endIndex
	 * @return
	 */
	ISaturnSQL build(String fullKey, String condition, int startIndex,
			int endIndex) throws Exception;
	/**
	 * 分页查询分区表SQL构建接口
	 * 
	 * @param fullKey
	 * @param condition
	 * @param startIndex
	 * @param endIndex
	 * @param tableWord 表名或分区语句关键字
	 * @return
	 */
	ISaturnSQL build(String fullKey, String condition,String tableWord, int startIndex,
			int endIndex) throws Exception;
}
